//
//  MSData.m
//  MyShare
//
//  Created by koki on 15/9/17.
//  Copyright (c) 2015年 MyShare. All rights reserved.
//

#import "MSData.h"

@implementation DOKeyValue

+(DOKeyValue*)key:(NSString*)key value:(NSString*)value
{
    DOKeyValue* kv=[[DOKeyValue alloc] init];
    kv.key=key;
    kv.value=value;
    return kv;
};

+(DOKeyValue*)key:(NSString*)key attributeValue:(NSAttributedString*)attributeValue
{
    DOKeyValue* kv=[[DOKeyValue alloc] init];
    kv.key=key;
    kv.attributeValue=attributeValue;
    return kv;
}
+ (DOKeyValue *)attributeKey:(NSAttributedString *)attKey attributeValue:(NSAttributedString *)attributeValue
{
    DOKeyValue *kv = [[DOKeyValue alloc] init];
    kv.attributeKey = attKey;
    kv.attributeValue = attributeValue;
    return kv;
}

+(DOKeyValue*)key:(NSString*)key value:(NSString*)value placeHolder:(NSString *)placeHolder
{
    DOKeyValue* kv=[[DOKeyValue alloc] init];
    kv.key=key;
    kv.value=value;
    kv.placeHolder = placeHolder;
    return kv;
}
- (id)copyWithZone:(NSZone *)zone
{
    DOKeyValue *newItem = [[DOKeyValue allocWithZone:zone] init];
    newItem.key = self.key;
    newItem.value = self.value;
    newItem.placeHolder = self.placeHolder;
    newItem.attributeValue = self.attributeValue;
    newItem.attributeKey = self.attributeKey;
    return newItem;
}

-(void)dealloc
{
    self.key = nil;
    self.value = nil;
    self.attributeValue = nil;
    self.attributeKey = nil;
}
@end
